{% extends "base.html" %}

{% block content %}

<h3>{{ title }}</h3>
<form method="post">
    {% csrf_token %}
    <table>
        {{ form.as_table }}
    </table>
    <input
        value="Submit"
        type="submit">
    <input
        value="Cancel"
        type="button"
        onclick="location.href='{% url "todos" tenant.id %}'">
    {% if object %}
    <input
        value="Delete this item"
        type="button"
        onclick="location.href=
        '{% url "item-delete" tenant.id object.id %}'">
    {% endif %}
</form>

{% endblock %}